<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jstl/fmt_rt" prefix="fmt"%>
<%@ taglib uri="http://www.springframework.org/tags" prefix="spring"%>
<%@ taglib uri="http://www.springframework.org/tags/form" prefix="form"%>
<%@ taglib uri="http://java.sun.com/jstl/core_rt" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title><spring:message  code="pim"/> - <c:out value="${bean.news.title}"></c:out></title>
<link href="<%= request.getContextPath() %>/css/custom.css" rel="stylesheet" type="text/css" />
<link href="<%= request.getContextPath() %>/css/style.css" rel="stylesheet" type="text/css" />
<link href="<%= request.getContextPath() %>/css/v.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="<%=request.getContextPath()%>/js/jquery-1.6.2.js"></script>
<%@include file="script/pim-util.jsp" %>
<style type="text/css">
.container img {
	max-width: 670px;
}
</style>
</head>
<body>
<c:if test="${bean.isSigned == true}">
<div id="all">
<div id="wrapper">
<div id="mainheader">
	<jsp:include page="include/common/headerSignedIn.jsp" />
</div> 
<div id="content-wrapper">
<div id="top-menu">
    <jsp:include page="include/common/topMenuHome.jsp" />
</div>
<div id="main-content">
<div class="container" style="padding: 10px;">
     <span class="author" style="float:right; padding: 20px;">	      	
       	 <fmt:formatDate value="${bean.news.createdAt}" pattern="EEEE, dd/MM/yyyy, hh:mm:ss"/>        			
	 </span>
	 <br/><br/>
	 <div class="new-manage-org-logo-org">			     				     
			<c:set value="${fn:trim(bean.news.imageurl)}" var="imageurl" />
			<c:choose>
			<c:when test="${imageurl == null || imageurl == ''}">
				<div class="logo" align="center">
					<img onLoad="scaleImg(this,150,120)" alt="" src="/pim/images/small_noImage.gif"/>
				</div>
			</c:when>
			<c:otherwise>
				<div class="logo" align="center">
					 <img alt="" src="${imageurl}" onLoad="scaleImg(this,150,120)"/>
				</div>
			</c:otherwise>
			</c:choose>					  
	 </div>
				 
	 <div class="new-manage-org-content">					
		<span class="new-manage-org-name"> 
		  <c:if test="${bean.isAdmin}">
			  <span class="v-bt-edit">
				  <a href="handleNews.htm?id=${bean.news.newsid}&cmd=edit" 
				      class="v-link" ><spring:message code="button.edit" />
				   </a>
			  </span>
			  &nbsp;
          </c:if>          				
		  <c:out value="${bean.news.title}"></c:out>				 	   
		</span>										
	</div>
				 															
	<div style="padding-left: 5px;text-align: justify;">
		<span class="pg-normal-introduction">					  
			<c:out value="${bean.news.description}"></c:out>									 
		</span>
	</div>	
	
	<div style="padding-left: 5px;text-align: justify;">
		<span class="pg-normal-content">					  
			<c:out value="${bean.news.content}" escapeXml="false"></c:out>									 
		</span>
	</div>
	
	<div style="text-align:right; padding-right: 30px; font-weight: bold;">
		<c:out value="${bean.news.createdBy}"></c:out>		
	</div>
	

	<div class="v-row-right" style="padding-bottom: 15px;">
		<span class="tg-content-blue" style="padding-right: 5px;">
			<a style="color: #30A1BE;text-decoration: none"  href="listnews.htm"><spring:message  code="back"/></a>
		</span>
	</div>	
  </div>			
 </div>
 
</div>
</div>
<div class="footer">
	<jsp:include page="include/common/footer.jsp" />
</div>
</div>
</c:if>
</body>
</html>